<div class="container-fluid" style="padding: 20px 10px 0px 10px">
    <div class="row-fluid">
        <div class="well">
            <ul class="nav nav-tabs">
                <li class="active"><b>商品管理</b></li>
            </ul>
            <div id="myTabContent" class="tab-content">
                <div class="tab-pane active in" id="home">
                    <form id="formid" action="/goods/setkcun" method="post">
                        <p>商品名称：<input type="text" value="<?=$getData['goods_title']?>" placeholder="商品名称" style="width:440px" name="goods_title" type='text' disabled></p>
                        <p>商品SKU：<input type="text" value="<?=$getData['goods_skuid']?>" placeholder="商品SkuId" style="width:440px" name="goods_skuid" type='text' disabled></p>
                        <p style="display:inline">商品价格：<input type="text" value="<?=$getData['goods_price']?>" placeholder="商品价格" style="width:65px" name="goods_price" type='text' disabled> 元 &nbsp;
                            / &nbsp;&nbsp;<input type="text" value="<?=$getData['goods_attr']?>" placeholder="件/个等" style="width:45px" name="goods_attr" type='text' disabled>&nbsp;&nbsp;
                            成本价格：<input type="text" style="width: 65px" value="{{$getData.channel_price}}" placeholder="成本价格" name="channel_price" />
                            &nbsp;&nbsp;<label style="display: inline;color: red">库存</label>：<input type="text" style="width: 40px;" value="{{$getData.kcun}}" placeholder="库存" name="kcun" class="kcun" />

                        </p>
                        <input type="hidden" value="<?=$getData['goods_id']?>" name="goods_id" />
                        <input type="hidden" value="1" name="dosubmit" />
                    </form>
                </div>
                <div class="btn-toolbar">
                    <button class="btn btn-primary" id="btn-save" style="margin:18px 0 0 70px"><i class="icon-save"></i> 保存</button>
                    <div class="btn-group">
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script>
    $(function(){
        $('#btn-save').click(function(){
            if(!$('.kcun').val()) {
                showmsg('库存不能为空');
                return false;
            }else{
                setBtn($('#btn-save'));
                $('#formid').submit();
            }
        });
    })
</script>